
jQuery(document).ready(function() {
       
     
    jQuery.getJSON("js/json/databusqueda.json", function(data) {
        jQuery.each(data, function(key, val) {
            jQuery(".ui-autocomplete-input").autocomplete({
                source: data

            });
               
            jQuery(".bus").click(function() {
                var palabra = jQuery("#inpu").val();
                var textjson = data[key]["value"];
                if (palabra === textjson) {
                    var url = data[key]["url"];
                    location.href = url;
                }

            });
           
        });
    });

});





